<a href='https://github.com/angular/angular.js/edit/v1.4.x/src/ngMock/angular-mocks.js?message=docs($rootScope.Scope)%3A%20describe%20your%20change...#L2116' class='improve-docs btn btn-primary'><i class="glyphicon glyphicon-edit">&nbsp;</i>Improve this Doc</a>



<a href='https://github.com/angular/angular.js/tree/v1.4.7/src/ngMock/angular-mocks.js#L2116' class='view-source pull-right btn btn-primary'>
  <i class="glyphicon glyphicon-zoom-in">&nbsp;</i>View Source
</a>


<header class="api-profile-header">
  <h1 class="api-profile-header-heading">$rootScope.Scope</h1>
  <ol class="api-profile-header-structure naked-list step-list">
    
    <li>
      - type in module <a href="api/ngMock">ngMock</a>
    </li>
  </ol>
</header>



<div class="api-profile-description">
  <p><a href="api/ng/type/$rootScope.Scope">Scope</a> type decorated with helper methods useful for testing. These
methods are automatically available on any <a href="api/ng/type/$rootScope.Scope">Scope</a> instance when
<code>ngMock</code> module is loaded.</p>
<p>In addition to all the regular <code>Scope</code> methods, the following helper methods are available:</p>

</div>




<div>
  

    

  

  
<h2>Methods</h2>
<ul class="methods">
  <li id="$countChildScopes">
    <h3><p><code>$countChildScopes();</code></p>

</h3>
    <div><p>Counts all the direct and indirect child scopes of the current scope.</p>
<p>The current scope is excluded from the count. The count includes all isolate child scopes.</p>
</div>

    

    
    
    
    <h4>Returns</h4>
    <table class="variables-matrix return-arguments">
  <tr>
    <td><a href="" class="label type-hint type-hint-number">number</a></td>
    <td><p>Total number of child scopes.</p>
</td>
  </tr>
</table>
    

  </li>
  
  <li id="$countWatchers">
    <h3><p><code>$countWatchers();</code></p>

</h3>
    <div><p>Counts all the watchers of direct and indirect child scopes of the current scope.</p>
<p>The watchers of the current scope are included in the count and so are all the watchers of
isolate child scopes.</p>
</div>

    

    
    
    
    <h4>Returns</h4>
    <table class="variables-matrix return-arguments">
  <tr>
    <td><a href="" class="label type-hint type-hint-number">number</a></td>
    <td><p>Total number of watchers.</p>
</td>
  </tr>
</table>
    

  </li>
  </ul>
  
  



  
</div>


